this._soundFile = null;
this._soundPlayed = false;
- source.connect('destroy', Lang.bind(this,
- function (source, reason) {
- this.destroy(reason);
- }));
-
this.actor = new St.Button({ accessible_role: Atk.Role.NOTIFICATION });
this.actor.add_style_class_name('notification-unexpanded');
this.actor._delegate = this;
destroy: function(reason) {
this.policy.destroy();
+
+ let notifications = this.notifications;
+ this.notifications = [];
+
+ for (let i = 0; i < notifications.length; i++)
+ notifications[i].destroy(reason);
+
this.emit('destroy', reason);
},